home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 26 / Cream of the Crop 26.iso / os2 / pvm34b3.zip / pvm34b3 / pvm3 / libfpvm / WIN32 / Pvmfjoingrp.c < prev    next >
C/C++ Source or Header  |  1997-07-22  |  728b  |  41 lines

  1.  
  2. /* $Id: Pvmfjoingrp.c,v 1.1 1997/06/27 16:27:05 pvmsrc Exp $ */
  3.  
  4. #ifdef WIN32
  5. #include "..\..\src\pvmwin.h"
  6. #endif 
  7. #include "pvm3.h"
  8. #include "pvm_consts.h"
  9.  
  10.  
  11. #ifdef __WATCOMC__
  12. #include "watforstr.h"
  13. #endif
  14. void __fortran
  15. #ifdef __WATCOMC__
  16. PVMFJOINGROUP (group_str, inum)
  17. WatcomFortranStr* group_str;
  18. int *inum;
  19. char* group_ptr = group_str->strP;
  20. int   group_len = group_str->len;
  21. #else
  22. PVMFJOINGROUP (group_ptr,group_len, inum)
  23. char * group_ptr; int group_len;
  24. int *inum;
  25. #endif
  26. {
  27.     char tgroup[MAX_GRP_NAME + 1];
  28.  
  29.     /*
  30.      * Copy the group name to make sure there's
  31.      * a NUL at the end.
  32.      */
  33.     if (ftocstr(tgroup, sizeof(tgroup), group_ptr, group_len)){
  34.         *inum = PvmBadParam;
  35.         return;
  36.     }
  37.  
  38.     *inum = pvm_joingroup(tgroup);
  39. }
  40.  
  41.